Skip to main content

Delete Invoice

DELETE /api/v1/Invoice/Delete

Description

This endpoint is used to delete an existing invoice. It returns a CreateInvoiceResponseResponse object containing information about the deleted invoice.

Headers:

  • None

ApiKey:

  • No API key required

Content-Type:

  • text/plain

  • application/json

  • text/json

Path Parameters:

  • version: string, required

Query Parameters:

  • InvoiceId: string, the unique identifier of the invoice to be deleted.

Request Body:

  • None

URL:

  • DELETE: {{baseUrl API url}}/api/v1/Invoice/Delete?InvoiceId=invoice_id_here

Response:

  • A CreateInvoiceResponseResponse object containing information about the deleted invoice.

Error Codes:

  • 400: Bad Request

  • 404: Resource not found

  • 500: Internal server error

Example:

Request:

DELETE /api/v1/Invoice/Delete?InvoiceId=1234567890

Response:

HTTP/1.1 200 OK
{
"invoiceId": "1234567890",
"counterpartyId": "0987654321",
"amount": 1500.00,
"currency": "USD",
"status": "Deleted",
"createdDate": "2024-02-19T00:00:00.000Z",
"dueDate": "2024-03-20T00:00:00.000Z"
}

Method: DELETE

/api/v1/Invoice/Delete?InvoiceId=<uuid>

Headers

Content-TypeValue
Accepttext/plain

Query Params

Paramvalue
InvoiceId<uuid>

Response: 200

{
"succeeded": "<boolean>",
"message": "<string>",
"errors": [
"<string>",
"<string>"
],
"data": {
"invoiceId": "<uuid>",
"amount": "<double>"
}
}

LANGUAGE

AUTHORIZATION

Bearer

CURL REQUEST


curl --request DELETE \ 
--url /api/v1/Invoice/Delete \
--header 'accept: application/json' \
--header 'content-type: application/json'

RESPONSE


Click Try It! to start a request and see the response here!